<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:s="http://jboss.com/products/seam/taglib"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:rich="http://richfaces.org/rich"
    template="layout/template.xhtml">

<ui:define name="body">

    <rich:panel>
        <f:facet name="header">City Details</f:facet>


        <s:decorate id="name" template="layout/display.xhtml">
            <ui:define name="label">Name</ui:define>
            <h:outputText value="#{cityHome.instance.name}"/>
        </s:decorate>

        <s:decorate id="lat" template="layout/display.xhtml">
            <ui:define name="label">Lat</ui:define>
            <h:outputText value="#{cityHome.instance.lat}"/>
        </s:decorate>

        <s:decorate id="lon" template="layout/display.xhtml">
            <ui:define name="label">Lon</ui:define>
            <h:outputText value="#{cityHome.instance.lon}"/>
        </s:decorate>

        <div style="clear:both"/>

    </rich:panel>

    <div class="actionButtons">

        <s:button view="/CityEdit.xhtml"
                    id="edit"
                 value="Edit"/>

        <s:button view="/#{empty cityFrom ? 'CityList' : cityFrom}.xhtml"
                    id="done"
                 value="Done"/>

    </div>

    <rich:tabPanel switchType="ajax">

    <rich:tab>
        <f:facet name="label">
            <h:panelGroup><h:graphicImage value="/img/manytoone.gif" style="vertical-align: middle; padding-right: 4px;"/>State</h:panelGroup>
        </f:facet>
    <div class="association" id="stateParent">

        <h:outputText value="There is no state associated with this city."
                   rendered="#{cityHome.instance.state == null}"/>

        <rich:dataTable var="_state"
                   value="#{cityHome.instance.state}"
                rendered="#{cityHome.instance.state != null}"
              rowClasses="rvgRowOne,rvgRowTwo"
                      id="stateTable">
            <h:column>
                <f:facet name="header">Id state</f:facet>
                <h:outputText value="#{_state.idState}"/>
            </h:column>
            <h:column>
                <f:facet name="header">Country id country</f:facet>
                <h:outputText value="#{_state.country.idCountry}"/>
            </h:column>
            <h:column>
                <f:facet name="header">Name</f:facet>
                <h:outputText value="#{_state.name}"/>
            </h:column>
            <h:column>
                <f:facet name="header">Code</f:facet>
                <h:outputText value="#{_state.code}"/>
            </h:column>
            <h:column styleClass="action">
                <f:facet name="header">Action</f:facet>
                <s:link id="viewstate"
                     value="View"
                      view="/State.xhtml">
                    <f:param name="stateIdState"
                           value="#{_state.idState}"/>
                </s:link>
            </h:column>
        </rich:dataTable>

    </div>
    </rich:tab>

    <rich:tab>
        <f:facet name="label">
            <h:panelGroup><h:graphicImage value="/img/onetomany.gif" style="vertical-align: middle; padding-right: 4px;"/>Requests for from city</h:panelGroup>
        </f:facet>
    <h:form styleClass="association" id="requestsForFromCityChildren">

        <h:outputText value="There are no requestsForFromCity associated with this city."
                   rendered="#{empty cityHome.requestsForFromCity}"/>

        <rich:dataTable value="#{cityHome.requestsForFromCity}"
                       var="_request"
                  rendered="#{not empty cityHome.requestsForFromCity}"
                rowClasses="rvgRowOne,rvgRowTwo"
                        id="requestsForFromCityTable">
            <rich:column sortBy="#{_request.idRequest}">
                <f:facet name="header">Id request</f:facet>
                <h:outputText value="#{_request.idRequest}"/>
            </rich:column>
            <rich:column sortBy="#{_request.name}">
                <f:facet name="header">Name</f:facet>
                <h:outputText value="#{_request.name}"/>
            </rich:column>
            <rich:column sortBy="#{_request.fromLat}">
                <f:facet name="header">From lat</f:facet>
                <h:outputText value="#{_request.fromLat}"/>
            </rich:column>
            <rich:column sortBy="#{_request.fromLon}">
                <f:facet name="header">From lon</f:facet>
                <h:outputText value="#{_request.fromLon}"/>
            </rich:column>
            <rich:column sortBy="#{_request.toLat}">
                <f:facet name="header">To lat</f:facet>
                <h:outputText value="#{_request.toLat}"/>
            </rich:column>
            <rich:column sortBy="#{_request.toLon}">
                <f:facet name="header">To lon</f:facet>
                <h:outputText value="#{_request.toLon}"/>
            </rich:column>
            <rich:column sortBy="#{_request.distance}">
                <f:facet name="header">Distance</f:facet>
                <h:outputText value="#{_request.distance}"/>
            </rich:column>
            <rich:column sortBy="#{_request.beginDate}">
                <f:facet name="header">Begin date</f:facet>
                <h:outputText value="#{_request.beginDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.endDate}">
                <f:facet name="header">End date</f:facet>
                <h:outputText value="#{_request.endDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.singleDay}">
                <f:facet name="header">Single day</f:facet>
                <h:outputText value="#{_request.singleDay}"/>
            </rich:column>
            <rich:column sortBy="#{_request.monday}">
                <f:facet name="header">Monday</f:facet>
                <h:outputText value="#{_request.monday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.tuesday}">
                <f:facet name="header">Tuesday</f:facet>
                <h:outputText value="#{_request.tuesday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.wednesday}">
                <f:facet name="header">Wednesday</f:facet>
                <h:outputText value="#{_request.wednesday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.thursday}">
                <f:facet name="header">Thursday</f:facet>
                <h:outputText value="#{_request.thursday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.friday}">
                <f:facet name="header">Friday</f:facet>
                <h:outputText value="#{_request.friday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.saturday}">
                <f:facet name="header">Saturday</f:facet>
                <h:outputText value="#{_request.saturday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.sunday}">
                <f:facet name="header">Sunday</f:facet>
                <h:outputText value="#{_request.sunday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.cronExpression}">
                <f:facet name="header">Cron expression</f:facet>
                <h:outputText value="#{_request.cronExpression}"/>
            </rich:column>
            <rich:column sortBy="#{_request.createDate}">
                <f:facet name="header">Create date</f:facet>
                <h:outputText value="#{_request.createDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.modifyDate}">
                <f:facet name="header">Modify date</f:facet>
                <h:outputText value="#{_request.modifyDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.deleteDate}">
                <f:facet name="header">Delete date</f:facet>
                <h:outputText value="#{_request.deleteDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <h:column>
                <f:facet name="header">Action</f:facet>
                <s:link id="selectrequest"
                     value="Select"
                      view="/Request.xhtml">
                    <f:param name="requestIdRequest"
                            value="#{_request.idRequest}"/>
                    <f:param name="requestFrom" value="City"/>
                </s:link>
            </h:column>
        </rich:dataTable>

    </h:form>

    <div class="actionButtons">
        <s:button
               value="Add request"
                view="/RequestEdit.xhtml">
            <f:param name="cityIdCity"
                    value="#{cityHome.instance.idCity}"/>
            <f:param name="requestFrom" value="City"/>
        </s:button>
    </div>
    </rich:tab>

    <rich:tab>
        <f:facet name="label">
            <h:panelGroup><h:graphicImage value="/img/onetomany.gif" style="vertical-align: middle; padding-right: 4px;"/>Requests for to city</h:panelGroup>
        </f:facet>
    <h:form styleClass="association" id="requestsForToCityChildren">

        <h:outputText value="There are no requestsForToCity associated with this city."
                   rendered="#{empty cityHome.requestsForToCity}"/>

        <rich:dataTable value="#{cityHome.requestsForToCity}"
                       var="_request"
                  rendered="#{not empty cityHome.requestsForToCity}"
                rowClasses="rvgRowOne,rvgRowTwo"
                        id="requestsForToCityTable">
            <rich:column sortBy="#{_request.idRequest}">
                <f:facet name="header">Id request</f:facet>
                <h:outputText value="#{_request.idRequest}"/>
            </rich:column>
            <rich:column sortBy="#{_request.name}">
                <f:facet name="header">Name</f:facet>
                <h:outputText value="#{_request.name}"/>
            </rich:column>
            <rich:column sortBy="#{_request.fromLat}">
                <f:facet name="header">From lat</f:facet>
                <h:outputText value="#{_request.fromLat}"/>
            </rich:column>
            <rich:column sortBy="#{_request.fromLon}">
                <f:facet name="header">From lon</f:facet>
                <h:outputText value="#{_request.fromLon}"/>
            </rich:column>
            <rich:column sortBy="#{_request.toLat}">
                <f:facet name="header">To lat</f:facet>
                <h:outputText value="#{_request.toLat}"/>
            </rich:column>
            <rich:column sortBy="#{_request.toLon}">
                <f:facet name="header">To lon</f:facet>
                <h:outputText value="#{_request.toLon}"/>
            </rich:column>
            <rich:column sortBy="#{_request.distance}">
                <f:facet name="header">Distance</f:facet>
                <h:outputText value="#{_request.distance}"/>
            </rich:column>
            <rich:column sortBy="#{_request.beginDate}">
                <f:facet name="header">Begin date</f:facet>
                <h:outputText value="#{_request.beginDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.endDate}">
                <f:facet name="header">End date</f:facet>
                <h:outputText value="#{_request.endDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.singleDay}">
                <f:facet name="header">Single day</f:facet>
                <h:outputText value="#{_request.singleDay}"/>
            </rich:column>
            <rich:column sortBy="#{_request.monday}">
                <f:facet name="header">Monday</f:facet>
                <h:outputText value="#{_request.monday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.tuesday}">
                <f:facet name="header">Tuesday</f:facet>
                <h:outputText value="#{_request.tuesday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.wednesday}">
                <f:facet name="header">Wednesday</f:facet>
                <h:outputText value="#{_request.wednesday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.thursday}">
                <f:facet name="header">Thursday</f:facet>
                <h:outputText value="#{_request.thursday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.friday}">
                <f:facet name="header">Friday</f:facet>
                <h:outputText value="#{_request.friday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.saturday}">
                <f:facet name="header">Saturday</f:facet>
                <h:outputText value="#{_request.saturday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.sunday}">
                <f:facet name="header">Sunday</f:facet>
                <h:outputText value="#{_request.sunday}"/>
            </rich:column>
            <rich:column sortBy="#{_request.cronExpression}">
                <f:facet name="header">Cron expression</f:facet>
                <h:outputText value="#{_request.cronExpression}"/>
            </rich:column>
            <rich:column sortBy="#{_request.createDate}">
                <f:facet name="header">Create date</f:facet>
                <h:outputText value="#{_request.createDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.modifyDate}">
                <f:facet name="header">Modify date</f:facet>
                <h:outputText value="#{_request.modifyDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_request.deleteDate}">
                <f:facet name="header">Delete date</f:facet>
                <h:outputText value="#{_request.deleteDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <h:column>
                <f:facet name="header">Action</f:facet>
                <s:link id="selectrequest"
                     value="Select"
                      view="/Request.xhtml">
                    <f:param name="requestIdRequest"
                            value="#{_request.idRequest}"/>
                    <f:param name="requestFrom" value="City"/>
                </s:link>
            </h:column>
        </rich:dataTable>

    </h:form>

    <div class="actionButtons">
        <s:button
               value="Add request"
                view="/RequestEdit.xhtml">
            <f:param name="cityIdCity"
                    value="#{cityHome.instance.idCity}"/>
            <f:param name="requestFrom" value="City"/>
        </s:button>
    </div>
    </rich:tab>

    <rich:tab>
        <f:facet name="label">
            <h:panelGroup><h:graphicImage value="/img/onetomany.gif" style="vertical-align: middle; padding-right: 4px;"/>Travels for to city</h:panelGroup>
        </f:facet>
    <h:form styleClass="association" id="travelsForToCityChildren">

        <h:outputText value="There are no travelsForToCity associated with this city."
                   rendered="#{empty cityHome.travelsForToCity}"/>

        <rich:dataTable value="#{cityHome.travelsForToCity}"
                       var="_travel"
                  rendered="#{not empty cityHome.travelsForToCity}"
                rowClasses="rvgRowOne,rvgRowTwo"
                        id="travelsForToCityTable">
            <rich:column sortBy="#{_travel.idTravel}">
                <f:facet name="header">Id travel</f:facet>
                <h:outputText value="#{_travel.idTravel}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.name}">
                <f:facet name="header">Name</f:facet>
                <h:outputText value="#{_travel.name}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.fromLat}">
                <f:facet name="header">From lat</f:facet>
                <h:outputText value="#{_travel.fromLat}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.fromLon}">
                <f:facet name="header">From lon</f:facet>
                <h:outputText value="#{_travel.fromLon}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.toLat}">
                <f:facet name="header">To lat</f:facet>
                <h:outputText value="#{_travel.toLat}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.toLon}">
                <f:facet name="header">To lon</f:facet>
                <h:outputText value="#{_travel.toLon}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.distance}">
                <f:facet name="header">Distance</f:facet>
                <h:outputText value="#{_travel.distance}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.travelState}">
                <f:facet name="header">Travel state</f:facet>
                <h:outputText value="#{_travel.travelState}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.calculatedRate}">
                <f:facet name="header">Calculated rate</f:facet>
                <h:outputText value="#{_travel.calculatedRate}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.createDate}">
                <f:facet name="header">Create date</f:facet>
                <h:outputText value="#{_travel.createDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.modifyDate}">
                <f:facet name="header">Modify date</f:facet>
                <h:outputText value="#{_travel.modifyDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.deleteDate}">
                <f:facet name="header">Delete date</f:facet>
                <h:outputText value="#{_travel.deleteDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.cronExpression}">
                <f:facet name="header">Cron expression</f:facet>
                <h:outputText value="#{_travel.cronExpression}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.monday}">
                <f:facet name="header">Monday</f:facet>
                <h:outputText value="#{_travel.monday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.tuesday}">
                <f:facet name="header">Tuesday</f:facet>
                <h:outputText value="#{_travel.tuesday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.wednesday}">
                <f:facet name="header">Wednesday</f:facet>
                <h:outputText value="#{_travel.wednesday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.thursday}">
                <f:facet name="header">Thursday</f:facet>
                <h:outputText value="#{_travel.thursday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.friday}">
                <f:facet name="header">Friday</f:facet>
                <h:outputText value="#{_travel.friday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.saturday}">
                <f:facet name="header">Saturday</f:facet>
                <h:outputText value="#{_travel.saturday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.sunday}">
                <f:facet name="header">Sunday</f:facet>
                <h:outputText value="#{_travel.sunday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.beginDate}">
                <f:facet name="header">Begin date</f:facet>
                <h:outputText value="#{_travel.beginDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.endDate}">
                <f:facet name="header">End date</f:facet>
                <h:outputText value="#{_travel.endDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.singleDay}">
                <f:facet name="header">Single day</f:facet>
                <h:outputText value="#{_travel.singleDay}"/>
            </rich:column>
            <h:column>
                <f:facet name="header">Action</f:facet>
                <s:link id="selecttravel"
                     value="Select"
                      view="/Travel.xhtml">
                    <f:param name="travelIdTravel"
                            value="#{_travel.idTravel}"/>
                    <f:param name="travelFrom" value="City"/>
                </s:link>
            </h:column>
        </rich:dataTable>

    </h:form>

    <div class="actionButtons">
        <s:button
               value="Add travel"
                view="/TravelEdit.xhtml">
            <f:param name="cityIdCity"
                    value="#{cityHome.instance.idCity}"/>
            <f:param name="travelFrom" value="City"/>
        </s:button>
    </div>
    </rich:tab>

    <rich:tab>
        <f:facet name="label">
            <h:panelGroup><h:graphicImage value="/img/onetomany.gif" style="vertical-align: middle; padding-right: 4px;"/>Travels for from city</h:panelGroup>
        </f:facet>
    <h:form styleClass="association" id="travelsForFromCityChildren">

        <h:outputText value="There are no travelsForFromCity associated with this city."
                   rendered="#{empty cityHome.travelsForFromCity}"/>

        <rich:dataTable value="#{cityHome.travelsForFromCity}"
                       var="_travel"
                  rendered="#{not empty cityHome.travelsForFromCity}"
                rowClasses="rvgRowOne,rvgRowTwo"
                        id="travelsForFromCityTable">
            <rich:column sortBy="#{_travel.idTravel}">
                <f:facet name="header">Id travel</f:facet>
                <h:outputText value="#{_travel.idTravel}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.name}">
                <f:facet name="header">Name</f:facet>
                <h:outputText value="#{_travel.name}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.fromLat}">
                <f:facet name="header">From lat</f:facet>
                <h:outputText value="#{_travel.fromLat}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.fromLon}">
                <f:facet name="header">From lon</f:facet>
                <h:outputText value="#{_travel.fromLon}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.toLat}">
                <f:facet name="header">To lat</f:facet>
                <h:outputText value="#{_travel.toLat}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.toLon}">
                <f:facet name="header">To lon</f:facet>
                <h:outputText value="#{_travel.toLon}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.distance}">
                <f:facet name="header">Distance</f:facet>
                <h:outputText value="#{_travel.distance}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.travelState}">
                <f:facet name="header">Travel state</f:facet>
                <h:outputText value="#{_travel.travelState}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.calculatedRate}">
                <f:facet name="header">Calculated rate</f:facet>
                <h:outputText value="#{_travel.calculatedRate}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.createDate}">
                <f:facet name="header">Create date</f:facet>
                <h:outputText value="#{_travel.createDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.modifyDate}">
                <f:facet name="header">Modify date</f:facet>
                <h:outputText value="#{_travel.modifyDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.deleteDate}">
                <f:facet name="header">Delete date</f:facet>
                <h:outputText value="#{_travel.deleteDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.cronExpression}">
                <f:facet name="header">Cron expression</f:facet>
                <h:outputText value="#{_travel.cronExpression}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.monday}">
                <f:facet name="header">Monday</f:facet>
                <h:outputText value="#{_travel.monday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.tuesday}">
                <f:facet name="header">Tuesday</f:facet>
                <h:outputText value="#{_travel.tuesday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.wednesday}">
                <f:facet name="header">Wednesday</f:facet>
                <h:outputText value="#{_travel.wednesday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.thursday}">
                <f:facet name="header">Thursday</f:facet>
                <h:outputText value="#{_travel.thursday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.friday}">
                <f:facet name="header">Friday</f:facet>
                <h:outputText value="#{_travel.friday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.saturday}">
                <f:facet name="header">Saturday</f:facet>
                <h:outputText value="#{_travel.saturday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.sunday}">
                <f:facet name="header">Sunday</f:facet>
                <h:outputText value="#{_travel.sunday}"/>
            </rich:column>
            <rich:column sortBy="#{_travel.beginDate}">
                <f:facet name="header">Begin date</f:facet>
                <h:outputText value="#{_travel.beginDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.endDate}">
                <f:facet name="header">End date</f:facet>
                <h:outputText value="#{_travel.endDate}">
                    <s:convertDateTime type="both" dateStyle="short"/>
                </h:outputText>
            </rich:column>
            <rich:column sortBy="#{_travel.singleDay}">
                <f:facet name="header">Single day</f:facet>
                <h:outputText value="#{_travel.singleDay}"/>
            </rich:column>
            <h:column>
                <f:facet name="header">Action</f:facet>
                <s:link id="selecttravel"
                     value="Select"
                      view="/Travel.xhtml">
                    <f:param name="travelIdTravel"
                            value="#{_travel.idTravel}"/>
                    <f:param name="travelFrom" value="City"/>
                </s:link>
            </h:column>
        </rich:dataTable>

    </h:form>

    <div class="actionButtons">
        <s:button
               value="Add travel"
                view="/TravelEdit.xhtml">
            <f:param name="cityIdCity"
                    value="#{cityHome.instance.idCity}"/>
            <f:param name="travelFrom" value="City"/>
        </s:button>
    </div>
    </rich:tab>
</rich:tabPanel>
</ui:define>

</ui:composition>
